package com.dfbz.demo01;

import java.util.Calendar;

/**
 * @author lscl
 * @version 1.0
 * @intro:
 */
public class Demo02_Calendar_设置 {
    public static void main(String[] args) {

        Calendar calendar = Calendar.getInstance();

        calendar.set(Calendar.YEAR,2021);
        calendar.set(Calendar.MONTH,7);
        calendar.set(Calendar.DAY_OF_MONTH,30);

        System.out.println(calendar.get(Calendar.YEAR));
        System.out.println(calendar.get(Calendar.MONTH));
        System.out.println(calendar.get(Calendar.DAY_OF_MONTH));

    }
}
